package com.wj.server.mapper;

import com.wj.server.pojo.Department;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author WangJin
 * @since 2022-02-26
 */
    public interface DepartmentMapper extends BaseMapper<Department> {
        /**
         * 获取所有部门
         *
         * @param parentId
         * @return
         */
        List<Department> getAllDepartmentsByParentId(Integer parentId);
        /**
         * 添加部门
         *
         * @param dep
         */
        void addDep(Department dep);
        /**
         * 删除部门
         *
         * @param dep
         */
        void deleteDep(Department dep);

    }
